package com.dao;

import com.pojo.Goods;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface GoodsMapper {
    @Insert("insert into goods (goods_id, goods_name,inventory,min,price) values (#{id}, #{name},{inventory}, #{min},{price})")
    boolean insert(Goods goods);


    @Select("select * from goods where goods_id = #{id}")
    Goods select(int id);

    @Select("select * from goods ")
    List<Goods> selectAllGoods();
}
